﻿using System;
using System.Text;

namespace GPS.GPSLanguage
{
    public enum DirectionType { Unknown, North, East, South, West };

    class DirectionTypeToken
    {
        public static String[] DirectionTypeText = { "Unknown", "North", "East", "South", "West" };

        internal static DirectionType ParseToken(string neswToken)
        {
            
                switch (neswToken)
                {
                    case "N":
                        return DirectionType.North;
                    case "E":
                        return DirectionType.East;
                    case "S":
                        return DirectionType.South;
                    case "W":
                        return DirectionType.West;
                    default:
                        return DirectionType.Unknown;
                }
            
            
        }
    }
}
